﻿using System;
using System.Data;
namespace Swd05.SH.Interfaces
{
	public interface IScriptFactory
	{
		// Creates an Instance of a ScriptEngine
		IScriptEngine Create( object context );
		// Connect to the Factory. Use the Parameter for configuration
		void Connect(string connectionstring);
		// Persist a Script, if the factory supports persistence.
		void Commit(string id, string stream);
		// Check, if there exists a script in the datasource
		bool Exists(string id);
		// Locate the Script by the Id
		string FindById(string id);
		// Return all Scripts from the Datastore
		DataTable Load();
	}
}
